package com.yuantu.judiciary.service;

import com.yuantu.judiciary.model.dto.*;
import com.yuantu.judiciary.model.enums.EndpointType;
import com.yuantu.judiciary.model.enums.SmsTemplateType;
import com.yuantu.judiciary.model.form.SendAuthorizedCodeAgainForm;
import com.yuantu.judiciary.model.form.SendAuthorizedCodeForm;
import com.yuantu.judiciary.model.form.SendCodeForm;
import com.yuantu.judiciary.model.form.VerifyCodeForm;
import com.yuantu.judiciary.model.vo.QueryResultSimpleVO;

/**
 * 短信模块接口
 *
 * @author syw
 * @since 2023-06-08
 **/
public interface ISmsService {


    Boolean sendMsgCode(String phone, SendCodeDataDTO codeData, SendAuthorizedMsgDataDTO authorizedMsgData, SmsTemplateType templateType);

    Boolean sendTimerMsgCode(String phone, SendTimerAuthDataDTO timerAuthData, SendTimerQueryDataDTO timerQueryData, SmsTemplateType templateType);

    /**
     * 发送短信验证码
     *
     * @param form 发送信息表单
     * @return true 表示操作成功；false 表示操作失败
     */
    Boolean sendCode(SendCodeForm form);

    /**
     * 验证短信验证码
     *
     * @param form 短信验证表单
     * @return true 表示操作成功；false 表示操作失败
     */
    Boolean verifyCode(VerifyCodeForm form);

    /**
     * 发送授权短信-个人尽调
     *
     * @param userId 用户id
     * @param endpointType 查询终端类型
     * @param form 发送授权短信表单
     * @return true 表示操作成功；false 表示操作失败
     */
    Boolean sendAuthorizedCode(Long userId, EndpointType endpointType, SendAuthorizedCodeForm form);

    Boolean sendAuthorizedCodeByAli(Long userId, SendAuthorizedCodeForm form);

    Long sendAuthorizedCodeBySelf(Long accountId, SendAuthorizedCodeForm form);

    QueryResultSimpleVO sendAuthorizedCodeBySelfForWx(Long accountId, String codeInfo);

    Boolean sendOrgAuthCode(Long accountId);

    Boolean sendAuthCode(AuthorizedInfoDTO authInfo);

    Boolean sendWarningCode(String count, String phone);

    Boolean sendAuthorizedCodeAgain(Long accountId, SendAuthorizedCodeAgainForm form);

    Boolean sendAuthSuccess(String phone, String cxr, String bcxr);
}
